cmake_minimum_required(VERSION 3.28)
project(asio VERSION 0.1.0 LANGUAGES C CXX)
set(CMAKE_CXX_STANDARD 23)

set(CMAKE_CXX_EXTENSIONS OFF)

add_executable(coro coro.ixx)

# 重新构建
# cmake .. -G Ninja --fresh

target_sources(coro
  PUBLIC
    FILE_SET CXX_MODULES FILES
    coro.ixx
)

#构建命令,不然gcc目前(2024-10-20)cpp modules不能使用
# mkdir build
# cd build 
# CXX=clang++ CC=clang cmake -G Ninja --fresh .. 

